import {FormBase, ControlType} from './form-base';

export class FormInput extends FormBase<string> {
    controlType: ControlType = 'input';
    disabled: boolean;
    placeholder: string;
    type: 'password' | 'email' | 'hidden' | 'text';

    constructor(options: {} = {}) {
        super(options);
        this.disabled = options['disabled'] || false;
        this.placeholder = options['placeholder'] || `请输入${options['key']}`;
        this.type = options['type'] || 'text';
    }
}
